Here is an example of Button 19 which will serve as the play button.
[Button19]
Action=-4
DllName=SkinName\WBAmp.dll
WBAmp=1
WBAmpShift=18
WBAmpCtrl=17
ButtonImage=SkinName\ButtonName.bmp
Visibility=26
Visibility1=19
Visibility2=1
...
[WBAmp]
DialogMode=0
Use the WBAmp Functions Table to lookup a function. Get its number.
Assign its value to the WBAmp entry of the button. To use Pause/Resume set WBAmp to 2, To use Stop set it to 3, etc.
The WBAmpShift entry specifies what function must be executed when the button is clicked while pressing the Shift key.
The WBAmpShift entry specifies what function must be executed when the button is clicked while pressing the Ctrl key.
Note that the WBAmp, WBAmpShift and WBAmpCtrl entry values must be present. There are no defaults. Note that the WBAmpShift and WBAmpCtrl entries are optional.
The visibility options as show here are optional, but I would suggest considering these. The number of buttons can become large and you will not always want to show them. In this example the button is show only when the window is not a dialog window (either the maximize or minimize buttons must exist), when the window is not a MDI window (this prevents more than one set of buttons in a MDI application) and when the window has the focus (this prevents the desktop to be crowded with WBAmp buttons).
All other button options can be used as normal. The "Plugin width" ("Width") and plugin height ("Height") parameters are ignored since WB draws the button. The plugin must be included in the same directory as the skin. Do not forget to include the plugin in the ZIP-file.
The [WBAmp] section describes WBAmp options. At the moment there is only the DialogMode entry. If set to 1 then the player is shown whenever a WBAmp button shows a dialog box.
There is one special button. It shows the current song title. It has to be declared a little bit different. This is an example.
[Button26]
Action=-3
DllName=DarkAmpXIII\WBAmp.dll
Align=1
XCoord=224
YCoord=4
Width=120
Height=20
Visibility=26
Visibility1=19
Visibility2=1
...
[WBAmp]
TitleBack=DarkAmpXIII\TitleBack.bmp
TitleMode=1
TimerInterval=1000
FontName=Arial
FontClip=4
FontHeight=0
FontWeight=0
FontItalic=0
FontUnderline=0
FontStrikeOut=0
FontColorR=255
FontColorG=255
FontColorB=255
The Action entry must be set to -3. This ensures that the plugin can update the button. Make shure that you do not specify a ButtonImage. If you do specify one than it uses resources that are never used. Instead use the TitleBack entry in the WBAmp section. That section also specifies the TitleMode. In this version there are only two modes. If the TitleMode is set to 1 then the button image contains two images (for the active and inactive state). If the TitleMode is ommited or set to 0 then no title and button will be displayed (just a black box). So you will have to set it to 1. Other values are reserved for future releases.
The "Width" and "Height" entries must be present. The number pixels along the X-axis of the TitleBack image must be equal to 2 x Width. The number of pixels along the Y-axis must be equal to Height.
The TitleBack image looks like a normal title bar button. It contains 2 images:
1: Active
2: Inactive
The TimerInterval entry sepecifies the timer interval in milliseconds. The lower the number the faster the update, but the higher the CPU usage. Infact Windows is not able to be very accurate. It uses the message queue for timer updates, which can be slow and inacurate. The default timer interval of 1 second (1000 milliseconds) is a good value. It increases CPU usage by 4% on a 500MHz PIII system.
The following font entries (in the WBAmp section) are optional:
FontName =Font name (less than 32 characters)
FontClip =Number of pixels to clip from left and right border
FontHeight =Pixels (negative value) or points (positive value)
The installation of CoolAmp is easy. Select "Options" from the menu, enable the "Scroll Songtitle" option. You may also want to disable the "Show on taskbar" option.
Whenever CoolPlayer is started it will show up on the system tray. Most skins do not show CoolPlayer by default. Some have an option to show it, but you can also double click the CoolPlayer icon.
The installation of WBAmp is actually a matter of configuring WinAmp correctly. Use the following WinAmp setting: At the WinAmp menu select "Options". Then "Preferences". Click "Display" in the tree. In the "Show WinAmp in:" box select "System tray only". This will prevent WinAmp from showing its ugly skin... If you now minimize WinAmp then it ends up in the SystemTray and will not be seen on the TaskBar. To restore it just single click the WinAmp icon in the SystemTray. Right clicking the icon on the SystemTray will show the WinAmp menu.
"I did what you said, but now I don't see WinAmp anymore..."
Well, that is the idea. You should not see WinAmp, unless you want it to be shown. If you start WinAmp, you do not see it either. If you go and look for it, you will find it in the SystemTray.
"The title bar is too small for the song title. How can I make it scroll?"
This is just another WinAmp setting. Open the WinAmp menu. Select "Options". Then "Preferences". Click "Display" in the tree. Finally check "Scroll song title in the Windows task bar". That's it. The text will not only scroll in the task bar, it will also scroll in the title bar of the skin.
You can either start the player as you used to or you can push any WBAmp button. It takes a while for it to start. During startup it cannot execute the action attached to the button. So the initial click just resulted in the player being started. This is not an error. You have to live with it OR add the player to your Startup menu. This causes the player to start whenever Windows starts.
You can check what version of WBAmp is installed by right clicking the WBAmp.dll file, then select Properties from the menu and finally click the Version tab.
If you design a skin and use WBAmp please be sure that dialog boxes do not have WBAmp buttons. Dialog boxes are used in error messages and since the player can produce errors it would be a bad idea to present WBAmp buttons while in the middle of handling player error.
Make shure that WBAmp buttons do not show up on MDI windows. You will end up in having them
duplicated. Also, I don't what happens if there are more than one visible title buttons. WBAmp does not support it and it can be a performance bottle neck.
Calling the WinAmp menu without showing WinAmp causes the menu to behave bad. Therefore WinAmp must be shown. Until there is a better solution WinAmp will be shown before the menu is opened.
Although CoolPlayer has some limitations (it is a pure MP3 player and WinAmp supports CDs and other formats) it behaves better (and some people say it sounds better) than WinAmp. WinAmp has various problems when WBAmp is calling its dialog boxes. CoolPlayer does not have these problems. Why? Niek Albers (programmer of CoolPlayer) did whatever he could to make this plugin work with his player. Again, thanks Niek! NullSoft (makers of WinAmp) did not even properly respond on the problems I had with their player. That reminds me. Sonique support is even worse. Next to that I had to drop support for Sonique altogether because of their limited command line interface.
Any WBAmp button can startup WinAmp (except WAClose). Not just WAPlay. Startup now rarely fails (I hope). If this fails then start it manually or even better add it to the Startup menu.
VIS dialog box options added. VISSelect does not seem to be working.
The Raise and Lower volume by 1% were swapped. This has been fixed.
I have asked NullSoft to help me with the dialog boxes. Some beta-testers did not like the current window to be pushed to the back. I have taken it out and hope NullSoft comes with an solution for the final build today.
Fixed a serious range checking bug. This bug only showed up when a non-existent function number was specified in the UIS file (number of functions + 1) and caused the skinned program to terminate.
There is still a bug when the window calls a dialog box. The title bar button is not updated correctly in that situation. I am working on that one.